Consult libpng-config more consistently.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 2 May 2014 19:34:03 +0000 (12:34 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 2 May 2014 19:34:03 +0000 (12:34 -0700)
commit43f5c5e08b969bc875b6fb2d0bccfa80fd5ecff6
tree85773352d151b825ff1959c72cf9e8fbe9b9e836
parent9047d2e8ee53d37e730c871b42001ba7912aa6be
Consult libpng-config more consistently.

* configure.ac (edit_cflags): Move this up and to the top level,
so that PNG_CFLAGS can use it too.
(PNG_CFLAGS): New var.
(png_longjmp): Use PNG_CFLAGS when checking.
(LIBPNG): Be consistent about -lpng16 etc; e.g., don't use -lpng16
in some places and -lpng in others.  Test libpng-config's exit
status.  If it succeeds, use its output rather than appending -lz -lm.
* src/Makefile.in (PNG_CFLAGS): New var.
(ALL_CFLAGS): Use it.
* src/image.c [HAVE_PNG]: Don't worry about <libpng/png.h>, as
CFLAGS now handles this.
ChangeLog
configure.ac
src/ChangeLog
src/Makefile.in
src/image.c